import type { RouteRecordRaw } from 'vue-router'
import UserCenterView from '../views/UserCenterView.vue'
import OrderView from '../views/OrderView.vue'

// 用户相关的路由配置
export const userRoutes: RouteRecordRaw[] = [
  {
    path: '/user-center',
    name: 'user-center',
    component: UserCenterView,
    meta: {
      title: '个人中心',
      requiresAuth: true
    }
  },
  {
    path: '/orders',
    name: 'orders',
    component: OrderView,
    meta: {
      title: '我的订单',
      requiresAuth: true
    }
  },
  // 注释掉未创建的路由
  // {
  //   path: '/account',
  //   name: 'account',
  //   component: () => import('../views/AccountView.vue'), // 懒加载
  //   meta: {
  //     title: '账户余额',
  //     requiresAuth: true
  //   }
  // }
]